package org.x.casemodule.enums;

public enum EvidenceType {
    //"DOCUMENT","PHYSICAL","TESTIMONY","DIGITAL"
    DOCUMENT("DOCUMENT","文档"),
    PHYSICAL("PHYSICAL","实体"),
    TESTIMONY("TESTIMONY","言词"),
    DIGITAL("DIGITAL","数字");

    private final String value;
    private final String description;

    EvidenceType(String value, String description) {
        this.value = value;
        this.description = description;
    }

    public String getValue() {
        return value;
    }
    public String getDescription() {
        return description;
    }
    public static EvidenceType getByValue(String value) {
        for (EvidenceType type : values()) {
            if (type.getValue().equals(value)) {
                return type;
            }
        }
        return null;
    }
    public static EvidenceType getByDescription(String description) {
        for (EvidenceType type : values()) {
            if (type.getDescription().equals(description)) {
                return type;
            }
        }
        return null;
    }

}
